//
//  ZBNavigator.h
//  ZBNavigator
//
//  Created by xzb on 2018/5/30.
//

#import <Foundation/Foundation.h>
#import "ZBNavigationController.h"



@interface ZBNavigator : NSObject

@property (nonatomic, strong, readonly) ZBNavigationController *currentNavigationController;

@property (nonatomic, strong, readonly) UIViewController *topVisibleViewController;

+ (instancetype)instance;

+ (BOOL)registerRoute;

- (BOOL)canPushViewController:(UIViewController *)viewController;

- (BOOL)pushViewController:(UIViewController *)viewController animated:(BOOL)animate;


- (BOOL)canPopViewController;

- (BOOL)popViewControllerAnimated:(BOOL)animate;


- (BOOL)canPopToViewController:(UIViewController *)viewController animated:(BOOL)animate;

- (BOOL)popToViewController:(UIViewController *)viewController animated:(BOOL)animate;


- (BOOL)canPresentViewController:(UIViewController *)viewController animated:(BOOL)animate completion:(void (^)(void))completion;

- (BOOL)presentViewController:(UIViewController *)viewController  animated:(BOOL)animate completion:(void (^)(void))completion;


- (BOOL)canDismissViewController:(BOOL)animate completion:(void (^)(void))completion;

- (BOOL)dismissViewController:(BOOL)animate completion:(void (^)(void))completion;

@end
